execute as @s[nbt={Inventory:[{Slot:-106b,tag:{battery:1b}}],SelectedItem:{id:"minecraft:iron_pickaxe",tag:{id:"advm:iron_drill"}}}] if score @s advm_IronDrillUse matches 1.. run function advm:skills/iron_drill_use
execute if score @s advm_IronDrillUse matches 1.. run scoreboard players set @s advm_IronDrillUse 0